package core {
	public class GameClass {
		private var classes:Vector.<Class> = new Vector.<Class>();

		public function GameClass(...componentClasses) {
			for (var i:int = 0; i < componentClasses.length; i++) {
				classes.push(componentClasses[i]);
			}
		}

		public function newObject():GameObject {
			var components:Vector.<Component> = new Vector.<Component>();
			for each (var componentClass:Class in classes) {
				var component:Component = new componentClass();
				components.push(component);
			}
			return new GameObject(components);
		}
	}
}
